<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="/jquery.js"></script>
</head>
<style>
    table {
        border: 1px solid black;
    }
    tr,th,td {
        width: 150px;
        height: 40px;
        border: 1px solid black;
    }
</style>
<body>
    <table>
        <thead>
            <tr>
                <th>姓名</th>
                <th>年龄</th>
                <th>婚姻状况</th>
            </tr>
        </thead>
        <tbody></tbody>
    </table>
</body>
<script>
    $(function(){
        $.ajax({
            url: 'http://127.0.0.1:5500/%E5%9B%9B%E6%AE%B5/ES6/%E5%B0%81%E8%A3%85%E5%87%BD%E6%95%B0.html',
            method: 'GET',
            dataType: 'json',
            success: function (lisis) {
                console.log(lisis);
                let str = ''
                for (let i in linis) {
                    str += `<tr>
                                <td>${lisis[i].name}</td>
                                <td>${lisis[i].age}</td>
                                <td>${lisis[i].marriage}</td>
                            </tr>`
                }
                $('tbody').html(str)
            }
        })
    })
</script>
</html>